lib/pull: Fix construction of a refspec to use the correct separator
authorPhilip Withnall <withnall@endlessm.com>
Wed, 7 Jun 2017 13:29:55 +0000 (14:29 +0100)
committerAtomic Bot <atomic-devel@projectatomic.io>
Tue, 13 Jun 2017 01:03:49 +0000 (01:03 +0000)
This code looks like it was supposed to build a refspec, but it used a
slash as a separator rather than a colon. The following code does
recover by supporting prefix matching with slashes, but it seems like
this was perhaps not the intention.

Signed-off-by: Philip Withnall <withnall@endlessm.com>
Closes: #912
Approved by: cgwalters

src/libostree/ostree-repo-pull.c

index ed782cd549f5ad20d7e44e24ff3a04c327436191..7f6d0123a21d3df2915d359aba2a1cab900869ab 100644 (file)
@@ -3392,7 +3392,7 @@ ostree_repo_pull_with_options (OstreeRepo             *self,
       g_autofree char *original_rev = NULL;
 
       if (pull_data->remote_name)
-        remote_ref = g_strdup_printf ("%s/%s", pull_data->remote_name, ref);
+        remote_ref = g_strdup_printf ("%s:%s", pull_data->remote_name, ref);
       else
         remote_ref = g_strdup (ref);